package com.cloud_sang.fubai.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.client.RestTemplate;

import javax.annotation.Resource;

/**
 * @ClassTitle: OrderController
 * @ProjectName springcould2020
 * @Description:
 * @Author Sangsang
 * @Date 2020/9/9
 * @Time 18:05
 */
@RestController
@Slf4j
public class OrderController {

	//public static final String PAYMENT_URL = "http://localhost:8001";
	public static final String INVOME_URL = "http://cloud-provider-payment";

	@Resource
	private RestTemplate restTemplate;


	@GetMapping("/consumer/payment/zk")
	public String payment (){
		String result = restTemplate.getForObject(INVOME_URL+"/payment/zk",String.class);
		return result;
	}


}
